package com.lyncs.ods.modules.msg.service;

import com.lyncs.ods.constant.LyncsOdsConstant;
import com.lyncs.ods.modules.company.model.CompanyInfo;

import java.util.List;

/**
 * @author alex
 * @date 2022/4/3 23:55
 * @description
 */
public interface MessageService {

    /**
     * 发送邮箱验证码
     *
     * @param email email
     */
    void sendEmailCode(String email);

    /**
     * 发送短信验证码
     *
     * @param phone phone
     */
    void sendSmsCode(String phone);

    /**
     * verifySmsCode
     *
     * @param phone phone
     * @param code  code
     * @return t/f
     */
    Boolean verifySmsCode(String phone, String code);

    /**
     * verifyEmailCode
     *
     * @param email email
     * @param code  code
     * @return t/f
     */
    Boolean verifyEmailCode(String email, String code);

    void sendNotifySms(LyncsOdsConstant.TxnType type, Long typeId, Long companyId, Long invitedCompanyId, String companyName, List<String> tos);

    void shareTicketByEmail(Boolean newTicket, LyncsOdsConstant.TxnType type, Long typeId, CompanyInfo companyInfo, CompanyInfo invitedCompanyInfo, List<String> tos);

    void shareTicketBySms(Boolean newTicket, LyncsOdsConstant.TxnType type, Long typeId, CompanyInfo companyInfo, Long invitedCompanyId, List<String> tos);

}
